[PATCH 1/2] output: optimize loop for finding alert http xff
authorPhilippe Antoine <pantoine@oisf.net>
Tue, 9 Dec 2025 08:21:58 +0000 (09:21 +0100)
committerAndreas Dolp <dev@andreas-dolp.de>
Thu, 23 Apr 2026 05:14:21 +0000 (07:14 +0200)
commit8dc5a3294ffd1545eb57521b16f4faa7765a9488
treedbf26821f91e482a5f423d923bf71c7a08d001fc
parentc46a1b2cdc2ea992a6be58cdec3ec28dbb8b8a1e
[PATCH 1/2] output: optimize loop for finding alert http xff

Ticket: 8156

In case of non-tx alerts, we try to loop over all the txs to find
the xff header. Do not start from tx_id 0, but from min_id
as AppLayerParserTransactionsCleanup to skip txs that were freed

(cherry picked from commit 3b1a6c1711b8f7d0bde4cb05f15cf50c751eda60)

Origin: upstream, https://github.com/OISF/suricata/commit/44d0c81f537f230e9215c769453fb4d7214217a1.patch
Bug: https://redmine.openinfosecfoundation.org/issues/8156
Subject: Upstream fix for CVE-2026-22261 part 1

Gbp-Pq: Name CVE-2026-22261_1.patch
src/app-layer-htp-xff.c
src/app-layer-parser.c
src/app-layer-parser.h